<h1 class="page-header">
    <small>员工管理</small>
</h1>
<hr/>
<div class="panel panel-inverse" data-sortable-id="form-stuff-5">
    <div class="panel-heading">
        <h4 class="panel-title">员工查询</h4>
    </div>
    <div class="panel-body">
        <form id="confirmerForm" name="confirmerForm" method="post" class="form-inline">
            <div class="form-group m-r-10">
                <input type="text" class="form-control" name="EQ_id" value="${params.EQ_id}"
                       placeholder="员工ID">
            </div>
            <div class="form-group m-r-10">
                <input type="text" class="form-control" name="LIKE_realName" value="${params.LIKE_realName}"
                       placeholder="姓名">
            </div>
            <div class="form-group m-r-10">
                <select class="form-control" name="EQ_storeId" id="EQ_storeId">
                    <option value="0">所属店铺</option>
                    <#if storeList?has_content && storeList?exists>
                    <#list storeList as pf>
                    <option value="${pf.id}" <#if pf.id == params.EQ_storeId > selected</#if> >${pf.name}</option>
                    </#list>
                </#if>
                </select>
            </div>
            <div class="form-group m-r-10">
                    <select class="form-control" name="EQ_auditedStatus" id="EQ_auditedStatus">
                        <option value="0" <#if ""== params.EQ_auditedStatus > selected</#if>>全部</option>
                        <option value="U" <#if "U"== params.EQ_auditedStatus > selected</#if>>待审核</option>
                        <option value="A" <#if "A"== params.EQ_auditedStatus > selected</#if>>已审核</option>
                        <option value="N" <#if "N"== params.EQ_auditedStatus > selected</#if>>已禁用</option>
                     </select>
            </div>
            <button type="button" class="btn btn-sm btn-success m-r-5"
                    onclick="postDataByForm('backend/confirmer/queryList','displayArea','confirmerForm')"><i class="fa fa-search"></i>查 询
            </button>
            <button type="button" class="btn btn-sm btn-danger m-r-5"
                    onclick="getData('${rc.contextPath}/backend/confirmer/add','displayArea')"><i class="fa fa-plus"></i>新增
            </button>
        </form>
    </div>
</div>
<hr/>
<div class="panel panel-inverse" data-sortable-id="table-basic-4">
    <div class="panel-heading">
        <h4 class="panel-title">员工列表</h4>
    </div>
    <div class="panel-body">
        <table class="table table-striped table-bordered">
            <thead>
            <tr>
                <th>编号</th>
                <th>姓名</th>
                <th>手机号</th>
                <th>归属店铺</th>
                <th>创建时间</th>
                <th>审核时间</th>
                <th>操作</th>
            </tr>
            </thead>
            <tbody>
            <#if paginationResponse?has_content && paginationResponse.content?exists && paginationResponse.content?size gt 0>
                <#list paginationResponse.content as ct>
                    <tr>
                        <td>${ct.id}</td>
                        <td>${ct.realName}</td>
                        <td>${ct.mobile}</td>
                        <td>${ct.storeName}</td>
                        <td>${ct.createTime}</td>
                        <td>${ct.auditedTime}</td>
                        <td>
                            <a class="label label-success small-btn" href="javascript:getData('${rc.contextPath}/backend/confirmer/confirmerEditInit/${ct.id}','displayArea')"><i class="fa fa-edit"></i>编辑</a>
                            <#if ct.auditedStatus == "A">
                            <a class="label label-danger small-btn" href="javascript:getConfirmData('确定删除吗?','${rc.contextPath}/backend/confirmer/unaudited/${ct.id}','displayArea');"><i class="fa fa-remove"></i>删除</a>
                            <#elseif ct.auditedStatus == "U">
                            <a class="label label-success small-btn" href="javascript:getConfirmData('确定审核通过吗?','${rc.contextPath}/backend/confirmer/audited/${ct.id}','displayArea');"><i class="fa fa-file-text"></i>审核通过</a>
                            <a class="label label-success small-btn" href="javascript:getConfirmData('确定审核不通过吗?','${rc.contextPath}/backend/confirmer/unaudited/${ct.id}','displayArea');"><i class="fa fa-trash"></i>审核不通过</a>
                            <#else>
                             -
                            </#if>

                        </td>
                    </tr>
                </#list>
            <#else>
            <tr class="gradeA even" role="row">
                <td colspan="12" class="text-center">没有符合条件的数据！</td>
            </tr>
            </#if>
        </table>
    </div>
</div>

<!-- 分页组件 -->
<!-- recordBean 分页查询结果Bean
     action 分页请求URL
     formName 分页需要的查询参数的表单名称 -->
<@sp.pagination recordBean=paginationResponse action="${rc.contextPath}/backend/confirmer/queryList" formName="confirmerForm"/>